﻿@model MyWorkBlogMVC.Models.CreateUserPostModel

@{
    ViewBag.Title = "CreateUserPost";
}
@Styles.Render("~/Content/css")
<link href="~/Content/UserPages.css" rel="stylesheet" />
<div class="jumbotron">
<img src="~/Content/blogme.PNG" />
</div>
<div class="title"><h2>Create blogpost</h2></div>

<div class="body_wrapper">
    <div class="content">


        @using (Html.BeginForm())
        {
            @Html.AntiForgeryToken()
            <div class="form-horizontal">
            @Html.ValidationSummary(true)

                <div class="form-group">
                    @Html.LabelFor(model => model.PostTitle, new { @class = "control-label col-md-2" })
                    <div class="col-md-10">
                        @Html.TextBoxFor(model => model.PostTitle)
                        @Html.ValidationMessageFor(model => model.PostTitle)
                    </div>
                </div>

                <div class="form-group">
                    @Html.LabelFor(model => model.PostContent, new { @class = "control-label col-md-2" })
                    <div class="blogpost_info">
                        @Html.TextAreaFor(model => model.PostContent)
                        @Html.ValidationMessageFor(model => model.PostContent)
                    </div>
                </div>

                <div class="form-group">
                    <div class="col-md-offset-2 col-md-10">
                        <input type="submit" value="Create" class="btn btn-default" />
                    </div>
                </div>
                <hr/>
                <div>
                    @Html.ActionLink("Back to List", "UserDetails")
                </div>
            </div>
        }
    </div>

    
</div>
